﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using AutoMapper;
using Sahit.iSoilHotel.Domain.MainBoundedContext.Tavern.Aggregates.AuthenticationAgg;
using Sahit.iSoilHotel.Application.MainBoundedContext.DTO.AuthenticationAgg;
using Sahit.iSoilHotel.Domain.MainBoundedContext.Tavern.Aggregates.RecordAgg;
using Sahit.iSoilHotel.Application.MainBoundedContext.DTO.RecordAgg;
using Sahit.iSoilHotel.Domain.MainBoundedContext.Tavern.Aggregates.RoomAgg;
using Sahit.iSoilHotel.Application.MainBoundedContext.DTO.RoomAgg;
using Sahit.iSoilHotel.Application.MainBoundedContext.DTO.PriceAgg;
using Sahit.iSoilHotel.Domain.MainBoundedContext.Tavern.Aggregates.PriceAgg;
using Sahit.iSoilHotel.Domain.MainBoundedContext.Tavern.Aggregates.CustomerAgg;
using Sahit.iSoilHotel.Application.MainBoundedContext.DTO.CustomerAgg;

namespace Sahit.iSoilHotel.Application.MainBoundedContext.DTO.Profiles
{
    class TavernProfile
         : Profile
    {
        protected override void Configure()
        {
            Mapper.CreateMap<Account, AccountDTO>();
            Mapper.CreateMap<AccountRole, AccountRoleDTO>();
            Mapper.CreateMap<Permission, PermissionDTO>();
            Mapper.CreateMap<Record, RecordDTO>();
            Mapper.CreateMap<Room, RoomDTO>();
            Mapper.CreateMap<RoomType, RoomTypeDTO>();
            Mapper.CreateMap<Price, PriceDTO>();
            Mapper.CreateMap<PriceCode, PriceCodeDTO>();
            Mapper.CreateMap<Customer, CustomerDTO>();
            Mapper.CreateMap<RecordStatus, RecordStatusDTO>();
            Mapper.CreateMap<Building, BuildingDTO>();

            Mapper.CreateMap<AccountDTO,Account>();
            Mapper.CreateMap<RecordDTO,Record>();
            Mapper.CreateMap<RoomDTO, Room>();
            Mapper.CreateMap<RoomTypeDTO, RoomType>();
            Mapper.CreateMap<PriceDTO, Price>();
            Mapper.CreateMap<PriceCodeDTO, PriceCode>();
            Mapper.CreateMap<CustomerDTO, Customer>().ForMember(m=>m.Type,x=>x.Ignore());
            Mapper.CreateMap<RecordStatusDTO, RecordStatus>();
            Mapper.CreateMap<BuildingDTO, Building>();
        }
    }
}
